<template>
	<view class="my-container">
		<!-- 用户未登录显示登陆组件 -->
		<my-login v-if="!token"></my-login>
		
		<!-- 登陆后显示用户信息组件 -->
		<my-user-info v-else></my-user-info>
	</view>
</template>

<script>
	import badgeMixin from '@/mixins/tabbar-badge.js'
	import {
		mapState
	} from 'vuex'

	export default {
		mixins: [badgeMixin],
		computed: {
			...mapState('user', ['token']),
		},
		data() {
			return {

			}
		},
		methods: {

		}
	}
</script>

<style lang="scss">
page,
.my-container {
  height: 100%;
}
</style>
